Autogenerated HTML docs for v2.13.0-rc1 
diff --git a/RelNotes/2.13.0.txt b/RelNotes/2.13.0.txt index b757fd1..f1560f1 100644 --- a/RelNotes/2.13.0.txt +++ b/RelNotes/2.13.0.txt 
@@ -186,6 +186,15 @@  size that can be expressed in size_t, which can be larger than  ulong on some platforms.   + * "git rebase" learns "--signoff" option. + + * The completion script (in contrib/) learned to complete "git push + --delete b<TAB>" to complete branch name to be deleted. + + * "git worktree add --lock" allows to lock a worktree immediately + after it's created. This helps prevent a race between "git worktree + add; git worktree lock" and "git worktree prune". +    Performance, Internal Implementation, Development Support etc.   @@ -302,6 +311,20 @@  file is used. Omit the validation during normal use, and instead  verify only in "git fsck".   + * Having a git command on the upstream side of a pipe in a test + script will hide the exit status from the command, which may cause + us to fail to notice a breakage; rewrite tests in a script to avoid + this issue. + + * Travis CI learns to run coccicheck. + + * "git checkout" that handles a lot of paths has been optimized by + reducing the number of unnecessary checks of paths in the + has_dir_name() function. + + * The internals of the refs API around the cached refs has been + streamlined. +  Also contains various documentation updates and code clean-ups.     @@ -535,6 +558,19 @@  using garbage past the end of the buffer.  (merge 5781a9a270 dt/xgethostname-nul-termination later to maint).   + * A recent update broke "git add -p ../foo" from a subdirectory. + + * While handy, "git_path()" is a dangerous function to use as a + callsite that uses it safely one day can be broken by changes + to other code that calls it. Reduction of its use continues. + (merge 16d2676c9e jk/war-on-git-path later to maint). + + * The split-index code configuration code used an unsafe git_path() + function without copying its result out. + + * Many stale HTTP(s) links have been updated in our documentation. + (merge 613416f0be jk/update-links-in-docs later to maint). +  * Other minor doc, test and build updates and code cleanups.  (merge df2a6e38b7 jk/pager-in-use later to maint).  (merge 75ec4a6cb0 ab/branch-list-doc later to maint). @@ -557,3 +593,6 @@  (merge d8f4481c4f jk/quarantine-received-objects later to maint).  (merge 7ba1ceef95 xy/format-patch-base later to maint).  (merge fa1912c89a rs/misc-cppcheck-fixes later to maint). + (merge f17d642d3b ab/push-cas-doc-n-test later to maint). + (merge 61e282425a ss/gitmodules-ignore-doc later to maint). + (merge 8d3047cd5b ss/submodule-shallow-doc later to maint). 
diff --git a/git-archimport.html b/git-archimport.html index 334408d..d3b4105 100644 --- a/git-archimport.html +++ b/git-archimport.html 
@@ -869,7 +869,7 @@  </dt>   <dd>   <p>  - Attempt to auto-register archives at <a href="http://mirrors.sourcecontrol.net">http://mirrors.sourcecontrol.net</a>  + Attempt to auto-register archives at <code>http://mirrors.sourcecontrol.net</code>   This is particularly useful with the -D option.   </p>   </dd>  @@ -902,7 +902,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2013-08-20 08:40:27 PDT  +Last updated 2017-04-26 19:19:22 PDT   </div>   </div>   </body>  
diff --git a/git-archimport.txt b/git-archimport.txt index 163b9f6..ea70653 100644 --- a/git-archimport.txt +++ b/git-archimport.txt 
@@ -96,7 +96,7 @@ 	pruned.    -a:: -	Attempt to auto-register archives at http://mirrors.sourcecontrol.net +	Attempt to auto-register archives at `http://mirrors.sourcecontrol.net` 	This is particularly useful with the -D option.    -t <tmpdir>:: 
diff --git a/git-bisect-lk2009.html b/git-bisect-lk2009.html index 5e784fc..3393da7 100644 --- a/git-bisect-lk2009.html +++ b/git-bisect-lk2009.html 
@@ -1931,17 +1931,17 @@  <div class="ulist"><ul>   <li>   <p>  -<a id="1"></a>[1] <a href="http://www.nist.gov/public_affairs/releases/n02-10.htm"><em>Software Errors Cost U.S. Economy $59.5 Billion Annually</em>. Nist News Release.</a>  +<a id="1"></a>[1] <a href="https://www.nist.gov/sites/default/files/documents/director/planning/report02-3.pdf"><em>The Economic Impacts of Inadequate Infratructure for Software Testing</em>. Nist Planning Report 02-3</a>, see Executive Summary and Chapter 8.   </p>   </li>   <li>   <p>  -<a id="2"></a>[2] <a href="http://java.sun.com/docs/codeconv/html/CodeConventions.doc.html#16712"><em>Code Conventions for the Java Programming Language</em>. Sun Microsystems.</a>  +<a id="2"></a>[2] <a href="http://www.oracle.com/technetwork/java/codeconvtoc-136057.html"><em>Code Conventions for the Java Programming Language</em>. Sun Microsystems.</a>   </p>   </li>   <li>   <p>  -<a id="3"></a>[3] <a href="http://en.wikipedia.org/wiki/Software_maintenance"><em>Software maintenance</em>. Wikipedia.</a>  +<a id="3"></a>[3] <a href="https://en.wikipedia.org/wiki/Software_maintenance"><em>Software maintenance</em>. Wikipedia.</a>   </p>   </li>   <li>  @@ -1951,12 +1951,12 @@  </li>   <li>   <p>  -<a id="5"></a>[5] <a href="http://lwn.net/Articles/317154/">Christian Couder. <em>Fully automated bisecting with "git bisect run"</em>. LWN.net.</a>  +<a id="5"></a>[5] <a href="https://lwn.net/Articles/317154/">Christian Couder. <em>Fully automated bisecting with "git bisect run"</em>. LWN.net.</a>   </p>   </li>   <li>   <p>  -<a id="6"></a>[6] <a href="http://lwn.net/Articles/277872/">Jonathan Corbet. <em>Bisection divides users and developers</em>. LWN.net.</a>  +<a id="6"></a>[6] <a href="https://lwn.net/Articles/277872/">Jonathan Corbet. <em>Bisection divides users and developers</em>. LWN.net.</a>   </p>   </li>   <li>  @@ -1966,12 +1966,12 @@  </li>   <li>   <p>  -<a id="8"></a>[8] <a href="http://www.kernel.org/pub/software/scm/git/docs/git-bisect.html">Junio C Hamano and the git-list. <em>git-bisect(1) Manual Page</em>. Linux Kernel Archives.</a>  +<a id="8"></a>[8] <a href="https://www.kernel.org/pub/software/scm/git/docs/git-bisect.html">Junio C Hamano and the git-list. <em>git-bisect(1) Manual Page</em>. Linux Kernel Archives.</a>   </p>   </li>   <li>   <p>  -<a id="9"></a>[9] <a href="http://github.com/Ealdwulf/bbchop">Ealdwulf. <em>bbchop</em>. GitHub.</a>  +<a id="9"></a>[9] <a href="https://github.com/Ealdwulf/bbchop">Ealdwulf. <em>bbchop</em>. GitHub.</a>   </p>   </li>   </ul></div>  @@ -1981,7 +1981,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2016-06-27 11:04:05 PDT  +Last updated 2017-04-26 19:19:22 PDT   </div>   </div>   </body>  
diff --git a/git-bisect-lk2009.txt b/git-bisect-lk2009.txt index e015f5b..8ac75fc 100644 --- a/git-bisect-lk2009.txt +++ b/git-bisect-lk2009.txt 
@@ -1347,12 +1347,12 @@  References  ----------   -- [[[1]]] http://www.nist.gov/public_affairs/releases/n02-10.htm['Software Errors Cost U.S. Economy $59.5 Billion Annually'. Nist News Release.] -- [[[2]]] http://java.sun.com/docs/codeconv/html/CodeConventions.doc.html#16712['Code Conventions for the Java Programming Language'. Sun Microsystems.] -- [[[3]]] http://en.wikipedia.org/wiki/Software_maintenance['Software maintenance'. Wikipedia.] +- [[[1]]] https://www.nist.gov/sites/default/files/documents/director/planning/report02-3.pdf['The Economic Impacts of Inadequate Infratructure for Software Testing'. Nist Planning Report 02-3], see Executive Summary and Chapter 8. +- [[[2]]] http://www.oracle.com/technetwork/java/codeconvtoc-136057.html['Code Conventions for the Java Programming Language'. Sun Microsystems.] +- [[[3]]] https://en.wikipedia.org/wiki/Software_maintenance['Software maintenance'. Wikipedia.]  - [[[4]]] http://article.gmane.org/gmane.comp.version-control.git/45195/[Junio C Hamano. 'Automated bisect success story'. Gmane.] -- [[[5]]] http://lwn.net/Articles/317154/[Christian Couder. 'Fully automated bisecting with "git bisect run"'. LWN.net.] -- [[[6]]] http://lwn.net/Articles/277872/[Jonathan Corbet. 'Bisection divides users and developers'. LWN.net.] +- [[[5]]] https://lwn.net/Articles/317154/[Christian Couder. 'Fully automated bisecting with "git bisect run"'. LWN.net.] +- [[[6]]] https://lwn.net/Articles/277872/[Jonathan Corbet. 'Bisection divides users and developers'. LWN.net.]  - [[[7]]] http://article.gmane.org/gmane.linux.scsi/36652/[Ingo Molnar. 'Re: BUG 2.6.23-rc3 can't see sd partitions on Alpha'. Gmane.] -- [[[8]]] http://www.kernel.org/pub/software/scm/git/docs/git-bisect.html[Junio C Hamano and the git-list. 'git-bisect(1) Manual Page'. Linux Kernel Archives.] -- [[[9]]] http://github.com/Ealdwulf/bbchop[Ealdwulf. 'bbchop'. GitHub.] +- [[[8]]] https://www.kernel.org/pub/software/scm/git/docs/git-bisect.html[Junio C Hamano and the git-list. 'git-bisect(1) Manual Page'. Linux Kernel Archives.] +- [[[9]]] https://github.com/Ealdwulf/bbchop[Ealdwulf. 'bbchop'. GitHub.] 
diff --git a/git-push.html b/git-push.html index 94874f4..b0af684 100644 --- a/git-push.html +++ b/git-push.html 
@@ -1030,6 +1030,47 @@  with this feature.</p></div>   <div class="paragraph"><p>"--no-force-with-lease" will cancel all the previous --force-with-lease on the   command line.</p></div>  +<div class="paragraph"><p>A general note on safety: supplying this option without an expected  +value, i.e. as <code>--force-with-lease</code> or <code>--force-with-lease=&lt;refname&gt;</code>  +interacts very badly with anything that implicitly runs <code>git fetch</code> on  +the remote to be pushed to in the background, e.g. <code>git fetch origin</code>  +on your repository in a cronjob.</p></div>  +<div class="paragraph"><p>The protection it offers over <code>--force</code> is ensuring that subsequent  +changes your work wasn&#8217;t based on aren&#8217;t clobbered, but this is  +trivially defeated if some background process is updating refs in the  +background. We don&#8217;t have anything except the remote tracking info to  +go by as a heuristic for refs you&#8217;re expected to have seen &amp; are  +willing to clobber.</p></div>  +<div class="paragraph"><p>If your editor or some other system is running <code>git fetch</code> in the  +background for you a way to mitigate this is to simply set up another  +remote:</p></div>  +<div class="literalblock">  +<div class="content">  +<pre><code>git remote add origin-push $(git config remote.origin.url)  +git fetch origin-push</code></pre>  +</div></div>  +<div class="paragraph"><p>Now when the background process runs <code>git fetch origin</code> the references  +on <code>origin-push</code> won&#8217;t be updated, and thus commands like:</p></div>  +<div class="literalblock">  +<div class="content">  +<pre><code>git push --force-with-lease origin-push</code></pre>  +</div></div>  +<div class="paragraph"><p>Will fail unless you manually run <code>git fetch origin-push</code>. This method  +is of course entirely defeated by something that runs <code>git fetch  +--all</code>, in that case you&#8217;d need to either disable it or do something  +more tedious like:</p></div>  +<div class="literalblock">  +<div class="content">  +<pre><code>git fetch # update 'master' from remote  +git tag base master # mark our base point  +git rebase -i master # rewrite some commits  +git push --force-with-lease=master:base master:master</code></pre>  +</div></div>  +<div class="paragraph"><p>I.e. create a <code>base</code> tag for versions of the upstream code that you&#8217;ve  +seen and are willing to overwrite, then rewrite history, and finally  +force push changes to <code>master</code> if the remote version is still at  +<code>base</code>, regardless of what your local <code>remotes/origin/master</code> has been  +updated to in the background.</p></div>   </dd>   <dt class="hdlist1">   -f  @@ -1831,7 +1872,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-02-15 15:17:51 PST  +Last updated 2017-04-26 19:19:22 PDT   </div>   </div>   </body>  
diff --git a/git-push.txt b/git-push.txt index 1624a35..0a63966 100644 --- a/git-push.txt +++ b/git-push.txt 
@@ -217,6 +217,47 @@  +  "--no-force-with-lease" will cancel all the previous --force-with-lease on the  command line. ++ +A general note on safety: supplying this option without an expected +value, i.e. as `--force-with-lease` or `--force-with-lease=<refname>` +interacts very badly with anything that implicitly runs `git fetch` on +the remote to be pushed to in the background, e.g. `git fetch origin` +on your repository in a cronjob. ++ +The protection it offers over `--force` is ensuring that subsequent +changes your work wasn't based on aren't clobbered, but this is +trivially defeated if some background process is updating refs in the +background. We don't have anything except the remote tracking info to +go by as a heuristic for refs you're expected to have seen & are +willing to clobber. ++ +If your editor or some other system is running `git fetch` in the +background for you a way to mitigate this is to simply set up another +remote: ++ +	git remote add origin-push $(git config remote.origin.url) +	git fetch origin-push ++ +Now when the background process runs `git fetch origin` the references +on `origin-push` won't be updated, and thus commands like: ++ +	git push --force-with-lease origin-push ++ +Will fail unless you manually run `git fetch origin-push`. This method +is of course entirely defeated by something that runs `git fetch +--all`, in that case you'd need to either disable it or do something +more tedious like: ++ +	git fetch # update 'master' from remote +	git tag base master # mark our base point +	git rebase -i master # rewrite some commits +	git push --force-with-lease=master:base master:master ++ +I.e. create a `base` tag for versions of the upstream code that you've +seen and are willing to overwrite, then rewrite history, and finally +force push changes to `master` if the remote version is still at +`base`, regardless of what your local `remotes/origin/master` has been +updated to in the background.    -f::  --force:: 
diff --git a/git-rebase.html b/git-rebase.html index 71bcbcc..c732864 100644 --- a/git-rebase.html +++ b/git-rebase.html 
@@ -1264,6 +1264,16 @@  </p>   </dd>   <dt class="hdlist1">  +--signoff  +</dt>  +<dd>  +<p>  + This flag is passed to <em>git am</em> to sign off all the rebased  + commits (see <a href="git-am.html">git-am(1)</a>). Incompatible with the  + --interactive option.  +</p>  +</dd>  +<dt class="hdlist1">   -i   </dt>   <dt class="hdlist1">  @@ -2032,7 +2042,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2016-12-19 16:18:00 PST  +Last updated 2017-04-26 19:19:22 PDT   </div>   </div>   </body>  
diff --git a/git-rebase.txt b/git-rebase.txt index 67d48e6..53f4e14 100644 --- a/git-rebase.txt +++ b/git-rebase.txt 
@@ -370,6 +370,11 @@ 	of the rebased commits (see linkgit:git-am[1]). 	Incompatible with the --interactive option.   +--signoff:: +	This flag is passed to 'git am' to sign off all the rebased +	commits (see linkgit:git-am[1]). Incompatible with the +	--interactive option. +  -i::  --interactive:: 	Make a list of the commits which are about to be rebased. Let the 
diff --git a/git-tools.html b/git-tools.html index 657a746..108856e 100644 --- a/git-tools.html +++ b/git-tools.html 
@@ -743,14 +743,14 @@  maintained here. These days, however, search engines fill that role much   more efficiently, so this manually-maintained list has been retired.</p></div>   <div class="paragraph"><p>See also the <code>contrib/</code> area, and the Git wiki:  -<a href="http://git.or.cz/gitwiki/InterfacesFrontendsAndTools">http://git.or.cz/gitwiki/InterfacesFrontendsAndTools</a></p></div>  +<a href="https://git.wiki.kernel.org/index.php/InterfacesFrontendsAndTools">https://git.wiki.kernel.org/index.php/InterfacesFrontendsAndTools</a></p></div>   </div>   </div>   </div>   <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2015-08-03 12:41:59 PDT  +Last updated 2017-04-26 19:19:22 PDT   </div>   </div>   </body>  
diff --git a/git-tools.txt b/git-tools.txt index 2f4ff50..d0fec4c 100644 --- a/git-tools.txt +++ b/git-tools.txt 
@@ -7,4 +7,4 @@  more efficiently, so this manually-maintained list has been retired.    See also the `contrib/` area, and the Git wiki: -http://git.or.cz/gitwiki/InterfacesFrontendsAndTools +https://git.wiki.kernel.org/index.php/InterfacesFrontendsAndTools 
diff --git a/git-worktree.html b/git-worktree.html index 54c7f3f..9871c06 100644 --- a/git-worktree.html +++ b/git-worktree.html 
@@ -748,7 +748,7 @@  <h2 id="_synopsis">SYNOPSIS</h2>   <div class="sectionbody">   <div class="verseblock">  -<pre class="content"><em>git worktree add</em> [-f] [--detach] [--checkout] [-b &lt;new-branch&gt;] &lt;path&gt; [&lt;branch&gt;]  +<pre class="content"><em>git worktree add</em> [-f] [--detach] [--checkout] [--lock] [-b &lt;new-branch&gt;] &lt;path&gt; [&lt;branch&gt;]   <em>git worktree list</em> [--porcelain]   <em>git worktree lock</em> [--reason &lt;string&gt;] &lt;worktree&gt;   <em>git worktree prune</em> [-n] [-v] [--expire &lt;expire&gt;]  @@ -896,6 +896,16 @@  </p>   </dd>   <dt class="hdlist1">  +--lock  +</dt>  +<dd>  +<p>  + Keep the working tree locked after creation. This is the  + equivalent of <code>git worktree lock</code> after <code>git worktree add</code>,  + but without race condition.  +</p>  +</dd>  +<dt class="hdlist1">   -n   </dt>   <dt class="hdlist1">  @@ -1098,7 +1108,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-02-24 11:00:28 PST  +Last updated 2017-04-26 19:19:22 PDT   </div>   </div>   </body>  
diff --git a/git-worktree.txt b/git-worktree.txt index 553cf84..b472acc 100644 --- a/git-worktree.txt +++ b/git-worktree.txt 
@@ -9,7 +9,7 @@  SYNOPSIS  --------  [verse] -'git worktree add' [-f] [--detach] [--checkout] [-b <new-branch>] <path> [<branch>] +'git worktree add' [-f] [--detach] [--checkout] [--lock] [-b <new-branch>] <path> [<branch>]  'git worktree list' [--porcelain]  'git worktree lock' [--reason <string>] <worktree>  'git worktree prune' [-n] [-v] [--expire <expire>] @@ -107,6 +107,11 @@ 	such as configuring sparse-checkout. See "Sparse checkout" 	in linkgit:git-read-tree[1].   +--lock:: +	Keep the working tree locked after creation. This is the +	equivalent of `git worktree lock` after `git worktree add`, +	but without race condition. +  -n::  --dry-run:: 	With `prune`, do not remove anything; just report what it would 
diff --git a/gitcore-tutorial.html b/gitcore-tutorial.html index 4e0faec..84fd3e7 100644 --- a/gitcore-tutorial.html +++ b/gitcore-tutorial.html 
@@ -2169,7 +2169,7 @@  convenient to organize your project with an informal hierarchy   of developers. Linux kernel development is run this way. There   is a nice illustration (page 17, "Merges to Mainline") in  -<a href="http://www.xenotime.net/linux/mentor/linux-mentoring-2006.pdf">Randy Dunlap&#8217;s presentation</a>.</p></div>  +<a href="https://web.archive.org/web/20120915203609/http://www.xenotime.net/linux/mentor/linux-mentoring-2006.pdf">Randy Dunlap&#8217;s presentation</a>.</p></div>   <div class="paragraph"><p>It should be stressed that this hierarchy is purely <strong>informal</strong>.   There is nothing fundamental in Git that enforces the "chain of   patch flow" this hierarchy implies. You do not have to pull  @@ -2457,7 +2457,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-02-15 15:17:51 PST  +Last updated 2017-04-26 19:19:22 PDT   </div>   </div>   </body>  
diff --git a/gitcore-tutorial.txt b/gitcore-tutorial.txt index 3a0ec8c..7577f27 100644 --- a/gitcore-tutorial.txt +++ b/gitcore-tutorial.txt 
@@ -1429,7 +1429,7 @@  convenient to organize your project with an informal hierarchy  of developers. Linux kernel development is run this way. There  is a nice illustration (page 17, "Merges to Mainline") in -http://www.xenotime.net/linux/mentor/linux-mentoring-2006.pdf[Randy Dunlap's presentation]. +https://web.archive.org/web/20120915203609/http://www.xenotime.net/linux/mentor/linux-mentoring-2006.pdf[Randy Dunlap's presentation].    It should be stressed that this hierarchy is purely *informal*.  There is nothing fundamental in Git that enforces the "chain of 
diff --git a/gitmodules.html b/gitmodules.html index d9fe4d7..7c2a547 100644 --- a/gitmodules.html +++ b/gitmodules.html 
@@ -835,22 +835,59 @@  <dd>   <p>   Defines under what circumstances "git status" and the diff family show  - a submodule as modified. When set to "all", it will never be considered  - modified (but will nonetheless show up in the output of status and  - commit when it has been staged), "dirty" will ignore all changes  - to the submodules work tree and  - takes only differences between the HEAD of the submodule and the commit  - recorded in the superproject into account. "untracked" will additionally  - let submodules with modified tracked files in their work tree show up.  - Using "none" (the default when this option is not set) also shows  - submodules that have untracked files in their work tree as changed.  - If this option is also present in the submodules entry in .git/config of  - the superproject, the setting there will override the one found in  - .gitmodules.  - Both settings can be overridden on the command line by using the  - "--ignore-submodule" option. The <em>git submodule</em> commands are not  - affected by this setting.  + a submodule as modified. The following values are supported:   </p>  +<div class="dlist"><dl>  +<dt class="hdlist1">  +all  +</dt>  +<dd>  +<p>  +The submodule will never be considered modified (but will  + nonetheless show up in the output of status and commit when it has  + been staged).  +</p>  +</dd>  +<dt class="hdlist1">  +dirty  +</dt>  +<dd>  +<p>  +All changes to the submodule&#8217;s work tree will be ignored, only  + committed differences between the HEAD of the submodule and its  + recorded state in the superproject are taken into account.  +</p>  +</dd>  +<dt class="hdlist1">  +untracked  +</dt>  +<dd>  +<p>  +Only untracked files in submodules will be ignored.  + Committed differences and modifications to tracked files will show  + up.  +</p>  +</dd>  +<dt class="hdlist1">  +none  +</dt>  +<dd>  +<p>  +No modifiations to submodules are ignored, all of committed  + differences, and modifications to tracked and untracked files are  + shown. This is the default option.  +</p>  +<div class="literalblock">  +<div class="content">  +<pre><code>If this option is also present in the submodules entry in .git/config  +of the superproject, the setting there will override the one found in  +.gitmodules.  +Both settings can be overridden on the command line by using the  +"--ignore-submodule" option. The 'git submodule' commands are not  +affected by this setting.</code></pre>  +</div></div>  +</dd>  +</dl></div>   </dd>   <dt class="hdlist1">   submodule.&lt;name&gt;.shallow  @@ -858,8 +895,8 @@  <dd>   <p>   When set to true, a clone of this submodule will be performed as a  - shallow clone unless the user explicitly asks for a non-shallow  - clone.  + shallow clone (with a history depth of 1) unless the user explicitly  + asks for a non-shallow clone.   </p>   </dd>   </dl></div>  @@ -902,7 +939,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2016-10-26 15:23:54 PDT  +Last updated 2017-04-26 19:19:22 PDT   </div>   </div>   </body>  
diff --git a/gitmodules.txt b/gitmodules.txt index 8f7c50f..db5d47e 100644 --- a/gitmodules.txt +++ b/gitmodules.txt 
@@ -66,17 +66,26 @@    submodule.<name>.ignore:: 	Defines under what circumstances "git status" and the diff family show -	a submodule as modified. When set to "all", it will never be considered -	modified (but will nonetheless show up in the output of status and -	commit when it has been staged), "dirty" will ignore all changes -	to the submodules work tree and -	takes only differences between the HEAD of the submodule and the commit -	recorded in the superproject into account. "untracked" will additionally -	let submodules with modified tracked files in their work tree show up. -	Using "none" (the default when this option is not set) also shows -	submodules that have untracked files in their work tree as changed. -	If this option is also present in the submodules entry in .git/config of -	the superproject, the setting there will override the one found in +	a submodule as modified. The following values are supported: + +	all;; The submodule will never be considered modified (but will + nonetheless show up in the output of status and commit when it has + been staged). + +	dirty;; All changes to the submodule's work tree will be ignored, only + committed differences between the HEAD of the submodule and its + recorded state in the superproject are taken into account. + +	untracked;; Only untracked files in submodules will be ignored. + Committed differences and modifications to tracked files will show + up. + +	none;; No modifiations to submodules are ignored, all of committed + differences, and modifications to tracked and untracked files are + shown. This is the default option. + +	If this option is also present in the submodules entry in .git/config +	of the superproject, the setting there will override the one found in 	.gitmodules. 	Both settings can be overridden on the command line by using the 	"--ignore-submodule" option. The 'git submodule' commands are not @@ -84,8 +93,8 @@    submodule.<name>.shallow:: 	When set to true, a clone of this submodule will be performed as a -	shallow clone unless the user explicitly asks for a non-shallow -	clone. +	shallow clone (with a history depth of 1) unless the user explicitly +	asks for a non-shallow clone.      EXAMPLES 
diff --git a/gitweb.conf.html b/gitweb.conf.html index ce9ad9e..081e503 100644 --- a/gitweb.conf.html +++ b/gitweb.conf.html 
@@ -1180,8 +1180,8 @@  <p>   URI and label (title) for the Git logo link (or your site logo,   if you chose to use different logo image). By default, these both  - refer to Git homepage, <a href="http://git-scm.com">http://git-scm.com</a>; in the past, they pointed  - to Git documentation at <a href="http://www.kernel.org">http://www.kernel.org</a>.  + refer to Git homepage, <a href="https://git-scm.com">https://git-scm.com</a>; in the past, they pointed  + to Git documentation at <a href="https://www.kernel.org">https://www.kernel.org</a>.   </p>   </dd>   </dl></div>  @@ -2003,7 +2003,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2016-10-03 15:26:35 PDT  +Last updated 2017-04-26 19:19:22 PDT   </div>   </div>   </body>  
diff --git a/gitweb.conf.txt b/gitweb.conf.txt index e632089..9c8982e 100644 --- a/gitweb.conf.txt +++ b/gitweb.conf.txt 
@@ -368,8 +368,8 @@  $logo_label:: 	URI and label (title) for the Git logo link (or your site logo, 	if you chose to use different logo image). By default, these both -	refer to Git homepage, http://git-scm.com[]; in the past, they pointed -	to Git documentation at http://www.kernel.org[]. +	refer to Git homepage, https://git-scm.com[]; in the past, they pointed +	to Git documentation at https://www.kernel.org[].      Changing gitweb's look 
diff --git a/howto-index.html b/howto-index.html index 6e47bc4..3c83046 100644 --- a/howto-index.html +++ b/howto-index.html 
@@ -790,7 +790,7 @@  </ul></div>   <div class="paragraph"><p>In this how-to article, JC talks about how he   uses the post-update hook to automate Git documentation page  -shown at <a href="http://www.kernel.org/pub/software/scm/git/docs/">http://www.kernel.org/pub/software/scm/git/docs/</a>.</p></div>  +shown at <a href="https://www.kernel.org/pub/software/scm/git/docs/">https://www.kernel.org/pub/software/scm/git/docs/</a>.</p></div>   <div class="ulist"><ul>   <li>   <p>  @@ -883,7 +883,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:23 PDT  +Last updated 2017-04-26 19:20:04 PDT   </div>   </div>   </body>  
diff --git a/howto-index.txt b/howto-index.txt index 8f2edca..67bd7ad 100644 --- a/howto-index.txt +++ b/howto-index.txt 
@@ -37,7 +37,7 @@    In this how-to article, JC talks about how he  uses the post-update hook to automate Git documentation page -shown at http://www.kernel.org/pub/software/scm/git/docs/. +shown at https://www.kernel.org/pub/software/scm/git/docs/.      * link:howto/recover-corrupted-blob-object.html[recover-corrupted-blob-object] by Linus Torvalds <torvalds@linux-foundation.org> 
diff --git a/howto/keep-canonical-history-correct.html b/howto/keep-canonical-history-correct.html index b0db2fa..b5eae12 100644 --- a/howto/keep-canonical-history-correct.html +++ b/howto/keep-canonical-history-correct.html 
@@ -936,7 +936,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:27 PDT  +Last updated 2017-04-26 19:20:08 PDT   </div>   </div>   </body>  
diff --git a/howto/maintain-git.html b/howto/maintain-git.html index c36764b..7013b31 100644 --- a/howto/maintain-git.html +++ b/howto/maintain-git.html 
@@ -1433,7 +1433,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:27 PDT  +Last updated 2017-04-26 19:20:08 PDT   </div>   </div>   </body>  
diff --git a/howto/new-command.html b/howto/new-command.html index 5d7bf3d..51e7651 100644 --- a/howto/new-command.html +++ b/howto/new-command.html 
@@ -861,7 +861,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:24 PDT  +Last updated 2017-04-26 19:20:05 PDT   </div>   </div>   </body>  
diff --git a/howto/rebase-from-internal-branch.html b/howto/rebase-from-internal-branch.html index bb17e11..920dfbe 100644 --- a/howto/rebase-from-internal-branch.html +++ b/howto/rebase-from-internal-branch.html 
@@ -893,7 +893,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:27 PDT  +Last updated 2017-04-26 19:20:08 PDT   </div>   </div>   </body>  
diff --git a/howto/rebuild-from-update-hook.html b/howto/rebuild-from-update-hook.html index 7dd7449..8c4733c 100644 --- a/howto/rebuild-from-update-hook.html +++ b/howto/rebuild-from-update-hook.html 
@@ -738,7 +738,7 @@  <div id="content">   <div id="preamble">   <div class="sectionbody">  -<div class="paragraph"><p>The pages under <a href="http://www.kernel.org/pub/software/scm/git/docs/">http://www.kernel.org/pub/software/scm/git/docs/</a>  +<div class="paragraph"><p>The pages under <a href="https://www.kernel.org/pub/software/scm/git/docs/">https://www.kernel.org/pub/software/scm/git/docs/</a>   are built from Documentation/ directory of the git.git project   and needed to be kept up-to-date. The www.kernel.org/ servers   are mirrored and I was told that the origin of the mirror is on  @@ -845,7 +845,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:27 PDT  +Last updated 2017-04-26 19:20:08 PDT   </div>   </div>   </body>  
diff --git a/howto/rebuild-from-update-hook.txt b/howto/rebuild-from-update-hook.txt index 25378f6..db219f5 100644 --- a/howto/rebuild-from-update-hook.txt +++ b/howto/rebuild-from-update-hook.txt 
@@ -4,13 +4,13 @@  Date: Fri, 26 Aug 2005 18:19:10 -0700  Abstract: In this how-to article, JC talks about how he  uses the post-update hook to automate Git documentation page - shown at http://www.kernel.org/pub/software/scm/git/docs/. + shown at https://www.kernel.org/pub/software/scm/git/docs/.  Content-type: text/asciidoc    How to rebuild from update hook  ===============================   -The pages under http://www.kernel.org/pub/software/scm/git/docs/ +The pages under https://www.kernel.org/pub/software/scm/git/docs/  are built from Documentation/ directory of the git.git project  and needed to be kept up-to-date. The www.kernel.org/ servers  are mirrored and I was told that the origin of the mirror is on 
diff --git a/howto/recover-corrupted-blob-object.html b/howto/recover-corrupted-blob-object.html index 33b665e..e70b11b 100644 --- a/howto/recover-corrupted-blob-object.html +++ b/howto/recover-corrupted-blob-object.html 
@@ -878,7 +878,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:27 PDT  +Last updated 2017-04-26 19:20:08 PDT   </div>   </div>   </body>  
diff --git a/howto/recover-corrupted-object-harder.html b/howto/recover-corrupted-object-harder.html index e49d832..a9233e8 100644 --- a/howto/recover-corrupted-object-harder.html +++ b/howto/recover-corrupted-object-harder.html 
@@ -1187,7 +1187,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:27 PDT  +Last updated 2017-04-26 19:20:08 PDT   </div>   </div>   </body>  
diff --git a/howto/revert-a-faulty-merge.html b/howto/revert-a-faulty-merge.html index ecabde0..5c9a39a 100644 --- a/howto/revert-a-faulty-merge.html +++ b/howto/revert-a-faulty-merge.html 
@@ -1023,7 +1023,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:26 PDT  +Last updated 2017-04-26 19:20:07 PDT   </div>   </div>   </body>  
diff --git a/howto/revert-branch-rebase.html b/howto/revert-branch-rebase.html index 324efd7..d37cce8 100644 --- a/howto/revert-branch-rebase.html +++ b/howto/revert-branch-rebase.html 
@@ -905,7 +905,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:24 PDT  +Last updated 2017-04-26 19:20:06 PDT   </div>   </div>   </body>  
diff --git a/howto/separating-topic-branches.html b/howto/separating-topic-branches.html index 0d2833a..57adc6b 100644 --- a/howto/separating-topic-branches.html +++ b/howto/separating-topic-branches.html 
@@ -839,7 +839,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:26 PDT  +Last updated 2017-04-26 19:20:07 PDT   </div>   </div>   </body>  
diff --git a/howto/setup-git-server-over-http.html b/howto/setup-git-server-over-http.html index d79a8fd..89e0473 100644 --- a/howto/setup-git-server-over-http.html +++ b/howto/setup-git-server-over-http.html 
@@ -1069,7 +1069,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:26 PDT  +Last updated 2017-04-26 19:20:07 PDT   </div>   </div>   </body>  
diff --git a/howto/update-hook-example.html b/howto/update-hook-example.html index cbd6296..22a61ba 100644 --- a/howto/update-hook-example.html +++ b/howto/update-hook-example.html 
@@ -928,7 +928,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:25 PDT  +Last updated 2017-04-26 19:20:07 PDT   </div>   </div>   </body>  
diff --git a/howto/use-git-daemon.html b/howto/use-git-daemon.html index 05859f1..95226df 100644 --- a/howto/use-git-daemon.html +++ b/howto/use-git-daemon.html 
@@ -789,7 +789,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:25 PDT  +Last updated 2017-04-26 19:20:06 PDT   </div>   </div>   </body>  
diff --git a/howto/using-merge-subtree.html b/howto/using-merge-subtree.html index 163cf97..c5ee646 100644 --- a/howto/using-merge-subtree.html +++ b/howto/using-merge-subtree.html 
@@ -846,7 +846,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:25 PDT  +Last updated 2017-04-26 19:20:06 PDT   </div>   </div>   </body>  
diff --git a/howto/using-signed-tag-in-pull-request.html b/howto/using-signed-tag-in-pull-request.html index cfa8b86..2d70372 100644 --- a/howto/using-signed-tag-in-pull-request.html +++ b/howto/using-signed-tag-in-pull-request.html 
@@ -950,7 +950,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:25 PDT  +Last updated 2017-04-26 19:20:06 PDT   </div>   </div>   </body>  
diff --git a/technical/api-index.html b/technical/api-index.html index cd4113e..0695972 100644 --- a/technical/api-index.html +++ b/technical/api-index.html 
@@ -893,7 +893,7 @@  <div id="footnotes"><hr /></div>   <div id="footer">   <div id="footer-text">  -Last updated 2017-04-19 22:33:33 PDT  +Last updated 2017-04-26 19:20:15 PDT   </div>   </div>   </body>  
diff --git a/user-manual.html b/user-manual.html index 50a3e15..b3879b4 100644 --- a/user-manual.html +++ b/user-manual.html 
@@ -1,5 +1,5 @@  <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> -<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>Git User Manual</title><link rel="stylesheet" type="text/css" href="docbook-xsl.css"><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div lang="en" class="book"><div class="titlepage"><div><div><h1 class="title"><a name="idp47073645260992"></a>Git User Manual</h1></div></div><hr></div><div class="toc"><p><b>Table of Contents</b></p><dl class="toc"><dt><span class="preface"><a href="#idp47073645262192"></a></span></dt><dt><span class="chapter"><a href="#repositories-and-branches">1. Repositories and Branches</a></span></dt><dd><dl><dt><span class="section"><a href="#how-to-get-a-git-repository">How to get a Git repository</a></span></dt><dt><span class="section"><a href="#how-to-check-out">How to check out a different version of a project</a></span></dt><dt><span class="section"><a href="#understanding-commits">Understanding History: Commits</a></span></dt><dd><dl><dt><span class="section"><a href="#understanding-reachability">Understanding history: commits, parents, and reachability</a></span></dt><dt><span class="section"><a href="#history-diagrams">Understanding history: History diagrams</a></span></dt><dt><span class="section"><a href="#what-is-a-branch">Understanding history: What is a branch?</a></span></dt></dl></dd><dt><span class="section"><a href="#manipulating-branches">Manipulating branches</a></span></dt><dt><span class="section"><a href="#detached-head">Examining an old version without creating a new branch</a></span></dt><dt><span class="section"><a href="#examining-remote-branches">Examining branches from a remote repository</a></span></dt><dt><span class="section"><a href="#how-git-stores-references">Naming branches, tags, and other references</a></span></dt><dt><span class="section"><a href="#Updating-a-repository-With-git-fetch">Updating a repository with git fetch</a></span></dt><dt><span class="section"><a href="#fetching-branches">Fetching branches from other repositories</a></span></dt></dl></dd><dt><span class="chapter"><a href="#exploring-git-history">2. Exploring Git history</a></span></dt><dd><dl><dt><span class="section"><a href="#using-bisect">How to use bisect to find a regression</a></span></dt><dt><span class="section"><a href="#naming-commits">Naming commits</a></span></dt><dt><span class="section"><a href="#creating-tags">Creating tags</a></span></dt><dt><span class="section"><a href="#browsing-revisions">Browsing revisions</a></span></dt><dt><span class="section"><a href="#generating-diffs">Generating diffs</a></span></dt><dt><span class="section"><a href="#viewing-old-file-versions">Viewing old file versions</a></span></dt><dt><span class="section"><a href="#history-examples">Examples</a></span></dt><dd><dl><dt><span class="section"><a href="#counting-commits-on-a-branch">Counting the number of commits on a branch</a></span></dt><dt><span class="section"><a href="#checking-for-equal-branches">Check whether two branches point at the same history</a></span></dt><dt><span class="section"><a href="#finding-tagged-descendants">Find first tagged version including a given fix</a></span></dt><dt><span class="section"><a href="#showing-commits-unique-to-a-branch">Showing commits unique to a given branch</a></span></dt><dt><span class="section"><a href="#making-a-release">Creating a changelog and tarball for a software release</a></span></dt><dt><span class="section"><a href="#Finding-commits-With-given-Content">Finding commits referencing a file with given content</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="#Developing-With-git">3. Developing with Git</a></span></dt><dd><dl><dt><span class="section"><a href="#telling-git-your-name">Telling Git your name</a></span></dt><dt><span class="section"><a href="#creating-a-new-repository">Creating a new repository</a></span></dt><dt><span class="section"><a href="#how-to-make-a-commit">How to make a commit</a></span></dt><dt><span class="section"><a href="#creating-good-commit-messages">Creating good commit messages</a></span></dt><dt><span class="section"><a href="#ignoring-files">Ignoring files</a></span></dt><dt><span class="section"><a href="#how-to-merge">How to merge</a></span></dt><dt><span class="section"><a href="#resolving-a-merge">Resolving a merge</a></span></dt><dd><dl><dt><span class="section"><a href="#conflict-resolution">Getting conflict-resolution help during a merge</a></span></dt></dl></dd><dt><span class="section"><a href="#undoing-a-merge">Undoing a merge</a></span></dt><dt><span class="section"><a href="#fast-forwards">Fast-forward merges</a></span></dt><dt><span class="section"><a href="#fixing-mistakes">Fixing mistakes</a></span></dt><dd><dl><dt><span class="section"><a href="#reverting-a-commit">Fixing a mistake with a new commit</a></span></dt><dt><span class="section"><a href="#fixing-a-mistake-by-rewriting-history">Fixing a mistake by rewriting history</a></span></dt><dt><span class="section"><a href="#checkout-of-path">Checking out an old version of a file</a></span></dt><dt><span class="section"><a href="#interrupted-work">Temporarily setting aside work in progress</a></span></dt></dl></dd><dt><span class="section"><a href="#ensuring-good-performance">Ensuring good performance</a></span></dt><dt><span class="section"><a href="#ensuring-reliability">Ensuring reliability</a></span></dt><dd><dl><dt><span class="section"><a href="#checking-for-corruption">Checking the repository for corruption</a></span></dt><dt><span class="section"><a href="#recovering-lost-changes">Recovering lost changes</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="#sharing-development">4. Sharing development with others</a></span></dt><dd><dl><dt><span class="section"><a href="#getting-updates-With-git-pull">Getting updates with git pull</a></span></dt><dt><span class="section"><a href="#submitting-patches">Submitting patches to a project</a></span></dt><dt><span class="section"><a href="#importing-patches">Importing patches to a project</a></span></dt><dt><span class="section"><a href="#public-repositories">Public Git repositories</a></span></dt><dd><dl><dt><span class="section"><a href="#setting-up-a-public-repository">Setting up a public repository</a></span></dt><dt><span class="section"><a href="#exporting-via-git">Exporting a Git repository via the Git protocol</a></span></dt><dt><span class="section"><a href="#exporting-via-http">Exporting a git repository via HTTP</a></span></dt><dt><span class="section"><a href="#pushing-changes-to-a-public-repository">Pushing changes to a public repository</a></span></dt><dt><span class="section"><a href="#forcing-push">What to do when a push fails</a></span></dt><dt><span class="section"><a href="#setting-up-a-shared-repository">Setting up a shared repository</a></span></dt><dt><span class="section"><a href="#setting-up-gitweb">Allowing web browsing of a repository</a></span></dt></dl></dd><dt><span class="section"><a href="#how-to-get-a-git-repository-with-minimal-history">How to get a Git repository with minimal history</a></span></dt><dt><span class="section"><a href="#sharing-development-examples">Examples</a></span></dt><dd><dl><dt><span class="section"><a href="#maintaining-topic-branches">Maintaining topic branches for a Linux subsystem maintainer</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="#cleaning-up-history">5. Rewriting history and maintaining patch series</a></span></dt><dd><dl><dt><span class="section"><a href="#patch-series">Creating the perfect patch series</a></span></dt><dt><span class="section"><a href="#using-git-rebase">Keeping a patch series up to date using git rebase</a></span></dt><dt><span class="section"><a href="#rewriting-one-commit">Rewriting a single commit</a></span></dt><dt><span class="section"><a href="#reordering-patch-series">Reordering or selecting from a patch series</a></span></dt><dt><span class="section"><a href="#interactive-rebase">Using interactive rebases</a></span></dt><dt><span class="section"><a href="#patch-series-tools">Other tools</a></span></dt><dt><span class="section"><a href="#problems-With-rewriting-history">Problems with rewriting history</a></span></dt><dt><span class="section"><a href="#bisect-merges">Why bisecting merge commits can be harder than bisecting linear history</a></span></dt></dl></dd><dt><span class="chapter"><a href="#advanced-branch-management">6. Advanced branch management</a></span></dt><dd><dl><dt><span class="section"><a href="#fetching-individual-branches">Fetching individual branches</a></span></dt><dt><span class="section"><a href="#fetch-fast-forwards">git fetch and fast-forwards</a></span></dt><dt><span class="section"><a href="#forcing-fetch">Forcing git fetch to do non-fast-forward updates</a></span></dt><dt><span class="section"><a href="#remote-branch-configuration">Configuring remote-tracking branches</a></span></dt></dl></dd><dt><span class="chapter"><a href="#git-concepts">7. Git concepts</a></span></dt><dd><dl><dt><span class="section"><a href="#the-object-database">The Object Database</a></span></dt><dd><dl><dt><span class="section"><a href="#commit-object">Commit Object</a></span></dt><dt><span class="section"><a href="#tree-object">Tree Object</a></span></dt><dt><span class="section"><a href="#blob-object">Blob Object</a></span></dt><dt><span class="section"><a href="#trust">Trust</a></span></dt><dt><span class="section"><a href="#tag-object">Tag Object</a></span></dt><dt><span class="section"><a href="#pack-files">How Git stores objects efficiently: pack files</a></span></dt><dt><span class="section"><a href="#dangling-objects">Dangling objects</a></span></dt><dt><span class="section"><a href="#recovering-from-repository-corruption">Recovering from repository corruption</a></span></dt></dl></dd><dt><span class="section"><a href="#the-index">The index</a></span></dt></dl></dd><dt><span class="chapter"><a href="#submodules">8. Submodules</a></span></dt><dd><dl><dt><span class="section"><a href="#_pitfalls_with_submodules">Pitfalls with submodules</a></span></dt></dl></dd><dt><span class="chapter"><a href="#low-level-operations">9. Low-level Git operations</a></span></dt><dd><dl><dt><span class="section"><a href="#object-manipulation">Object access and manipulation</a></span></dt><dt><span class="section"><a href="#the-workflow">The Workflow</a></span></dt><dd><dl><dt><span class="section"><a href="#working-directory-to-index">working directory → index</a></span></dt><dt><span class="section"><a href="#index-to-object-database">index → object database</a></span></dt><dt><span class="section"><a href="#object-database-to-index">object database → index</a></span></dt><dt><span class="section"><a href="#index-to-working-directory">index → working directory</a></span></dt><dt><span class="section"><a href="#tying-it-all-together">Tying it all together</a></span></dt></dl></dd><dt><span class="section"><a href="#examining-the-data">Examining the data</a></span></dt><dt><span class="section"><a href="#merging-multiple-trees">Merging multiple trees</a></span></dt><dt><span class="section"><a href="#merging-multiple-trees-2">Merging multiple trees, continued</a></span></dt></dl></dd><dt><span class="chapter"><a href="#hacking-git">10. Hacking Git</a></span></dt><dd><dl><dt><span class="section"><a href="#object-details">Object storage format</a></span></dt><dt><span class="section"><a href="#birdview-on-the-source-code">A birds-eye view of Git’s source code</a></span></dt></dl></dd><dt><span class="chapter"><a href="#glossary">11. Git Glossary</a></span></dt><dd><dl><dt><span class="section"><a href="#git-explained">Git explained</a></span></dt></dl></dd><dt><span class="appendix"><a href="#git-quick-start">A. Git Quick Reference</a></span></dt><dd><dl><dt><span class="section"><a href="#quick-creating-a-new-repository">Creating a new repository</a></span></dt><dt><span class="section"><a href="#managing-branches">Managing branches</a></span></dt><dt><span class="section"><a href="#exploring-history">Exploring history</a></span></dt><dt><span class="section"><a href="#making-changes">Making changes</a></span></dt><dt><span class="section"><a href="#merging">Merging</a></span></dt><dt><span class="section"><a href="#sharing-your-changes">Sharing your changes</a></span></dt><dt><span class="section"><a href="#repository-maintenance">Repository maintenance</a></span></dt></dl></dd><dt><span class="appendix"><a href="#todo">B. Notes and todo list for this manual</a></span></dt><dd><dl><dt><span class="section"><a href="#todo-list">Todo list</a></span></dt></dl></dd></dl></div><div class="preface"><div class="titlepage"><div><div><h1 class="title"><a name="idp47073645262192"></a></h1></div></div></div><p>Git is a fast distributed revision control system.</p><p>This manual is designed to be readable by someone with basic UNIX +<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>Git User Manual</title><link rel="stylesheet" type="text/css" href="docbook-xsl.css"><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div lang="en" class="book"><div class="titlepage"><div><div><h1 class="title"><a name="idp46617790242048"></a>Git User Manual</h1></div></div><hr></div><div class="toc"><p><b>Table of Contents</b></p><dl class="toc"><dt><span class="preface"><a href="#idp46617790243248"></a></span></dt><dt><span class="chapter"><a href="#repositories-and-branches">1. Repositories and Branches</a></span></dt><dd><dl><dt><span class="section"><a href="#how-to-get-a-git-repository">How to get a Git repository</a></span></dt><dt><span class="section"><a href="#how-to-check-out">How to check out a different version of a project</a></span></dt><dt><span class="section"><a href="#understanding-commits">Understanding History: Commits</a></span></dt><dd><dl><dt><span class="section"><a href="#understanding-reachability">Understanding history: commits, parents, and reachability</a></span></dt><dt><span class="section"><a href="#history-diagrams">Understanding history: History diagrams</a></span></dt><dt><span class="section"><a href="#what-is-a-branch">Understanding history: What is a branch?</a></span></dt></dl></dd><dt><span class="section"><a href="#manipulating-branches">Manipulating branches</a></span></dt><dt><span class="section"><a href="#detached-head">Examining an old version without creating a new branch</a></span></dt><dt><span class="section"><a href="#examining-remote-branches">Examining branches from a remote repository</a></span></dt><dt><span class="section"><a href="#how-git-stores-references">Naming branches, tags, and other references</a></span></dt><dt><span class="section"><a href="#Updating-a-repository-With-git-fetch">Updating a repository with git fetch</a></span></dt><dt><span class="section"><a href="#fetching-branches">Fetching branches from other repositories</a></span></dt></dl></dd><dt><span class="chapter"><a href="#exploring-git-history">2. Exploring Git history</a></span></dt><dd><dl><dt><span class="section"><a href="#using-bisect">How to use bisect to find a regression</a></span></dt><dt><span class="section"><a href="#naming-commits">Naming commits</a></span></dt><dt><span class="section"><a href="#creating-tags">Creating tags</a></span></dt><dt><span class="section"><a href="#browsing-revisions">Browsing revisions</a></span></dt><dt><span class="section"><a href="#generating-diffs">Generating diffs</a></span></dt><dt><span class="section"><a href="#viewing-old-file-versions">Viewing old file versions</a></span></dt><dt><span class="section"><a href="#history-examples">Examples</a></span></dt><dd><dl><dt><span class="section"><a href="#counting-commits-on-a-branch">Counting the number of commits on a branch</a></span></dt><dt><span class="section"><a href="#checking-for-equal-branches">Check whether two branches point at the same history</a></span></dt><dt><span class="section"><a href="#finding-tagged-descendants">Find first tagged version including a given fix</a></span></dt><dt><span class="section"><a href="#showing-commits-unique-to-a-branch">Showing commits unique to a given branch</a></span></dt><dt><span class="section"><a href="#making-a-release">Creating a changelog and tarball for a software release</a></span></dt><dt><span class="section"><a href="#Finding-commits-With-given-Content">Finding commits referencing a file with given content</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="#Developing-With-git">3. Developing with Git</a></span></dt><dd><dl><dt><span class="section"><a href="#telling-git-your-name">Telling Git your name</a></span></dt><dt><span class="section"><a href="#creating-a-new-repository">Creating a new repository</a></span></dt><dt><span class="section"><a href="#how-to-make-a-commit">How to make a commit</a></span></dt><dt><span class="section"><a href="#creating-good-commit-messages">Creating good commit messages</a></span></dt><dt><span class="section"><a href="#ignoring-files">Ignoring files</a></span></dt><dt><span class="section"><a href="#how-to-merge">How to merge</a></span></dt><dt><span class="section"><a href="#resolving-a-merge">Resolving a merge</a></span></dt><dd><dl><dt><span class="section"><a href="#conflict-resolution">Getting conflict-resolution help during a merge</a></span></dt></dl></dd><dt><span class="section"><a href="#undoing-a-merge">Undoing a merge</a></span></dt><dt><span class="section"><a href="#fast-forwards">Fast-forward merges</a></span></dt><dt><span class="section"><a href="#fixing-mistakes">Fixing mistakes</a></span></dt><dd><dl><dt><span class="section"><a href="#reverting-a-commit">Fixing a mistake with a new commit</a></span></dt><dt><span class="section"><a href="#fixing-a-mistake-by-rewriting-history">Fixing a mistake by rewriting history</a></span></dt><dt><span class="section"><a href="#checkout-of-path">Checking out an old version of a file</a></span></dt><dt><span class="section"><a href="#interrupted-work">Temporarily setting aside work in progress</a></span></dt></dl></dd><dt><span class="section"><a href="#ensuring-good-performance">Ensuring good performance</a></span></dt><dt><span class="section"><a href="#ensuring-reliability">Ensuring reliability</a></span></dt><dd><dl><dt><span class="section"><a href="#checking-for-corruption">Checking the repository for corruption</a></span></dt><dt><span class="section"><a href="#recovering-lost-changes">Recovering lost changes</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="#sharing-development">4. Sharing development with others</a></span></dt><dd><dl><dt><span class="section"><a href="#getting-updates-With-git-pull">Getting updates with git pull</a></span></dt><dt><span class="section"><a href="#submitting-patches">Submitting patches to a project</a></span></dt><dt><span class="section"><a href="#importing-patches">Importing patches to a project</a></span></dt><dt><span class="section"><a href="#public-repositories">Public Git repositories</a></span></dt><dd><dl><dt><span class="section"><a href="#setting-up-a-public-repository">Setting up a public repository</a></span></dt><dt><span class="section"><a href="#exporting-via-git">Exporting a Git repository via the Git protocol</a></span></dt><dt><span class="section"><a href="#exporting-via-http">Exporting a git repository via HTTP</a></span></dt><dt><span class="section"><a href="#pushing-changes-to-a-public-repository">Pushing changes to a public repository</a></span></dt><dt><span class="section"><a href="#forcing-push">What to do when a push fails</a></span></dt><dt><span class="section"><a href="#setting-up-a-shared-repository">Setting up a shared repository</a></span></dt><dt><span class="section"><a href="#setting-up-gitweb">Allowing web browsing of a repository</a></span></dt></dl></dd><dt><span class="section"><a href="#how-to-get-a-git-repository-with-minimal-history">How to get a Git repository with minimal history</a></span></dt><dt><span class="section"><a href="#sharing-development-examples">Examples</a></span></dt><dd><dl><dt><span class="section"><a href="#maintaining-topic-branches">Maintaining topic branches for a Linux subsystem maintainer</a></span></dt></dl></dd></dl></dd><dt><span class="chapter"><a href="#cleaning-up-history">5. Rewriting history and maintaining patch series</a></span></dt><dd><dl><dt><span class="section"><a href="#patch-series">Creating the perfect patch series</a></span></dt><dt><span class="section"><a href="#using-git-rebase">Keeping a patch series up to date using git rebase</a></span></dt><dt><span class="section"><a href="#rewriting-one-commit">Rewriting a single commit</a></span></dt><dt><span class="section"><a href="#reordering-patch-series">Reordering or selecting from a patch series</a></span></dt><dt><span class="section"><a href="#interactive-rebase">Using interactive rebases</a></span></dt><dt><span class="section"><a href="#patch-series-tools">Other tools</a></span></dt><dt><span class="section"><a href="#problems-With-rewriting-history">Problems with rewriting history</a></span></dt><dt><span class="section"><a href="#bisect-merges">Why bisecting merge commits can be harder than bisecting linear history</a></span></dt></dl></dd><dt><span class="chapter"><a href="#advanced-branch-management">6. Advanced branch management</a></span></dt><dd><dl><dt><span class="section"><a href="#fetching-individual-branches">Fetching individual branches</a></span></dt><dt><span class="section"><a href="#fetch-fast-forwards">git fetch and fast-forwards</a></span></dt><dt><span class="section"><a href="#forcing-fetch">Forcing git fetch to do non-fast-forward updates</a></span></dt><dt><span class="section"><a href="#remote-branch-configuration">Configuring remote-tracking branches</a></span></dt></dl></dd><dt><span class="chapter"><a href="#git-concepts">7. Git concepts</a></span></dt><dd><dl><dt><span class="section"><a href="#the-object-database">The Object Database</a></span></dt><dd><dl><dt><span class="section"><a href="#commit-object">Commit Object</a></span></dt><dt><span class="section"><a href="#tree-object">Tree Object</a></span></dt><dt><span class="section"><a href="#blob-object">Blob Object</a></span></dt><dt><span class="section"><a href="#trust">Trust</a></span></dt><dt><span class="section"><a href="#tag-object">Tag Object</a></span></dt><dt><span class="section"><a href="#pack-files">How Git stores objects efficiently: pack files</a></span></dt><dt><span class="section"><a href="#dangling-objects">Dangling objects</a></span></dt><dt><span class="section"><a href="#recovering-from-repository-corruption">Recovering from repository corruption</a></span></dt></dl></dd><dt><span class="section"><a href="#the-index">The index</a></span></dt></dl></dd><dt><span class="chapter"><a href="#submodules">8. Submodules</a></span></dt><dd><dl><dt><span class="section"><a href="#_pitfalls_with_submodules">Pitfalls with submodules</a></span></dt></dl></dd><dt><span class="chapter"><a href="#low-level-operations">9. Low-level Git operations</a></span></dt><dd><dl><dt><span class="section"><a href="#object-manipulation">Object access and manipulation</a></span></dt><dt><span class="section"><a href="#the-workflow">The Workflow</a></span></dt><dd><dl><dt><span class="section"><a href="#working-directory-to-index">working directory → index</a></span></dt><dt><span class="section"><a href="#index-to-object-database">index → object database</a></span></dt><dt><span class="section"><a href="#object-database-to-index">object database → index</a></span></dt><dt><span class="section"><a href="#index-to-working-directory">index → working directory</a></span></dt><dt><span class="section"><a href="#tying-it-all-together">Tying it all together</a></span></dt></dl></dd><dt><span class="section"><a href="#examining-the-data">Examining the data</a></span></dt><dt><span class="section"><a href="#merging-multiple-trees">Merging multiple trees</a></span></dt><dt><span class="section"><a href="#merging-multiple-trees-2">Merging multiple trees, continued</a></span></dt></dl></dd><dt><span class="chapter"><a href="#hacking-git">10. Hacking Git</a></span></dt><dd><dl><dt><span class="section"><a href="#object-details">Object storage format</a></span></dt><dt><span class="section"><a href="#birdview-on-the-source-code">A birds-eye view of Git’s source code</a></span></dt></dl></dd><dt><span class="chapter"><a href="#glossary">11. Git Glossary</a></span></dt><dd><dl><dt><span class="section"><a href="#git-explained">Git explained</a></span></dt></dl></dd><dt><span class="appendix"><a href="#git-quick-start">A. Git Quick Reference</a></span></dt><dd><dl><dt><span class="section"><a href="#quick-creating-a-new-repository">Creating a new repository</a></span></dt><dt><span class="section"><a href="#managing-branches">Managing branches</a></span></dt><dt><span class="section"><a href="#exploring-history">Exploring history</a></span></dt><dt><span class="section"><a href="#making-changes">Making changes</a></span></dt><dt><span class="section"><a href="#merging">Merging</a></span></dt><dt><span class="section"><a href="#sharing-your-changes">Sharing your changes</a></span></dt><dt><span class="section"><a href="#repository-maintenance">Repository maintenance</a></span></dt></dl></dd><dt><span class="appendix"><a href="#todo">B. Notes and todo list for this manual</a></span></dt><dd><dl><dt><span class="section"><a href="#todo-list">Todo list</a></span></dt></dl></dd></dl></div><div class="preface"><div class="titlepage"><div><div><h1 class="title"><a name="idp46617790243248"></a></h1></div></div></div><p>Git is a fast distributed revision control system.</p><p>This manual is designed to be readable by someone with basic UNIX  command-line skills, but no previous knowledge of Git.</p><p><a class="xref" href="#repositories-and-branches" title="Chapter 1. Repositories and Branches">Chapter 1, <i>Repositories and Branches</i></a> and <a class="xref" href="#exploring-git-history" title="Chapter 2. Exploring Git history">Chapter 2, <i>Exploring Git history</i></a> explain how  to fetch and study a project using git—read these chapters to learn how  to build and test a particular version of a software project, search for